<?php
//Duong dan tuyet doi
define('ROOT_PATH',realpath(dirname(__FILE__)));
defined('APPLICATION_PATH')
    || define('APPLICATION_PATH',
              realpath(dirname(__FILE__) . '/application'));


// Define application environment
defined('APPLICATION_ENV')
    || define('APPLICATION_ENV',
              (getenv('APPLICATION_ENV') ? getenv('APPLICATION_ENV')
                                         : 'developer'));

set_include_path(implode(PATH_SEPARATOR, array(
    dirname(__FILE__) . '/library',
	get_include_path(),
)));
define('DS', DIRECTORY_SEPARATOR);
define('PS', PATH_SEPARATOR);
define('PUBLIC_PATH',dirname(__FILE__).'/public');
define('LAYOUT_PATH',PUBLIC_PATH . '/layout');
define('FILE_PATH', PUBLIC_PATH . '/files');


//Duong dan tuong doi
if(APPLICATION_ENV == 'developer') {
    define('BASE_URL', 'http://'.$_SERVER['SERVER_NAME'].'/computer');
}else{
    define('BASE_URL', 'http://'.$_SERVER['SERVER_NAME']);
}
define('PUBLIC_URL',BASE_URL . '/public');
define('LAYOUT_URL',PUBLIC_URL . '/layout');

//Khai bao co dung Route hay khong
define('ROUTE', true);